/*
 * Copyright (c) 2024. Shanghai HEADING information Engineering Co., Ltd. All rights reserved.
 */
package com.lovely602.design.study.basic;

import java.util.Arrays;

/**
 * @author lizhixing
 */
public class ArrayTest {

  public static void main(String[] args) {
    int[] a = new int[] { 1, 2, 3, 4, 5 };
    a[2] = 4;
    int[] b = new int[5];
    b[4] = 5;
    // 错误创建方式，这种创建出来的数组不可以赋值
    int[] c = new int[] {};
    System.out.println(Arrays.toString(a));
    System.out.println(Arrays.toString(b));
    System.out.println(Arrays.toString(c));
  }
}